const Router = require("koa-router");
const { verifyToken } = require("../middeleware/auth.middleware");
const {
  getOrder,
  getSort,
  getbase,
  getProfit,
} = require("../controller/order.controller");

const orderRouter = new Router({ prefix: "/order" });

orderRouter.get("/base/:id", verifyToken, getbase);
orderRouter.get("/sort", verifyToken, getSort);
// 获取利润
orderRouter.get("/profit", verifyToken, getProfit);
// 获取所有order
orderRouter.get("/", verifyToken, getOrder);

module.exports = orderRouter;
